package cn.edu.service;

import cn.edu.config.SpringConfig;
import cn.edu.domain.Student;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringJUnit4ClassRunner;

import java.util.List;

/**
 * @author Davey chan
 */
@RunWith(SpringJUnit4ClassRunner.class)
@ContextConfiguration(classes = SpringConfig.class)
public class test {
    @Autowired
    private StudentService studentService;
    @Test
    public void test01(){
        List<Student> all = studentService.findAll();
        System.out.println(all);
    }
}
